package xyz.haijin.zt.mysql.model;


import java.util.List;

/**
 * 复杂条件构造
 * @Auther liuhaijin
 * @Date 2021/7/30
 */
public class PredicateExpress {
    /**
     * 条件谓词
     */
    private String op;
    /**
     * 字段名，驼峰形式会转换成下划线形式，如：字段名：userNme -> user_name
     */
    private String key;
    /**
     * 条件值
     */
    private Object value;
    /**
     * BETWEEN 值1
     */
    private Object betweenValue1;
    /**
     * BETWEEN 值2
     */
    private Object betweenValue2;
    /**
     * 值类型
     */
    private String valueType;
    /**
     * 嵌套的具体条件
     */
    private List<PredicateExpress> predicates;

    public PredicateExpress() {
    }

    public String getKey() {
        return key;
    }

    public String getOp() {
        return this.op;
    }

    public Object getValue() {
        return this.value;
    }

    public Object getBetweenValue1() {
        return this.betweenValue1;
    }

    public Object getBetweenValue2() {
        return this.betweenValue2;
    }

    public String getValueType() {
        return this.valueType;
    }

    public List<PredicateExpress> getPredicates() {
        return this.predicates;
    }

    public void setOp(String op) {
        this.op = op;
    }

    public void setKey(String key) {
        this.key = key;
    }

    public void setValue(Object value) {
        this.value = value;
    }

    public void setBetweenValue1(Object betweenValue1) {
        this.betweenValue1 = betweenValue1;
    }

    public void setBetweenValue2(Object betweenValue2) {
        this.betweenValue2 = betweenValue2;
    }

    public void setValueType(String valueType) {
        this.valueType = valueType;
    }

    public void setPredicates(List<PredicateExpress> predicates) {
        this.predicates = predicates;
    }

}
